In current communication transmission, increasing attention is paid to quality of voice signals or audio signals. Therefore, quality requirements for signal encoding and decoding are increasingly high. In existing frequency domain encoding algorithms, bit allocation is generally performed on each sub-band of a signal directly according to a size of a frequency envelope, and then each sub-band is encoded by using a quantity of allocated bits. However, practice shows that, in these existing encoding algorithms, sub-bands of a low frequency band have relatively large impact on signal encoding quality. Therefore, the sub-bands of the low frequency band generally become a bottleneck of signal encoding performance. The foregoing bit allocation manner cannot well adapt to a bit requirement of each sub-band, especially that of a sub-band of a low frequency band, which leads to relatively poor signal encoding performance. Correspondingly, signal decoding performance is also relatively poor.